package leetcode_1100;

public class DivisorGame_1025 {
	public static void main(String[] args) {
		DivisorGame_1025 test = new DivisorGame_1025();
		System.out.println(test.divisorGame(2));
		System.out.println(test.divisorGame(4));
		System.out.println(test.divisorGame(3));
	}
	 public boolean divisorGame(int N) {
	      boolean dp[] = new boolean[N+1];
	      dp[1] = false;
	      for(int i=2;i<=N;++i) {
	    	  for(int j=1;j<i;++j) {
	    		  if(!dp[j] && i%(i-j) == 0) {
	    			  dp[i] = true;
	    			  break;
	    		  }
	    	  }
	      }
	      return dp[N];
	 }
}
